#delimit; 
clear all;
set more off;

capture log close;

log using covid_stringency_index.log, replace;

import excel "owid-covid-data.xlsx", sheet("owid-covid-data") firstrow;

keep if location=="United States";
su;

gen tudate=date;
format tudate %tdnn/dd/CCYY;
keep tudate stringency_index; 
keep if tudate>=mdy(1,1,2020) & tudate<=mdy(12,31,2021);
su;

twoway (line stringency_index tudate, ytitle("Stringency index")), 
       tline(1march2021) tlabel(1march2021 "3/1/2021", add angle(45)) xtitle("Date") ;
graph save stringency_index, replace;	  

save covid_stringency_index.dta, replace;

log close;